package site.yunnong.atvris.service.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import site.yunnong.atvris.common.api.Page;

import java.time.LocalDateTime;

/**
 * 带回复的评论vo
 * @author zjh
 * @date 2021/7/13 23:55
 */
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class CommentCardVO {
    
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long id;
    
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long uuid;
    
    @ApiModelProperty("关联媒体唯一标识，视频/动态")
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    private Long mediaId;
    
    @ApiModelProperty("媒体评论， 见MediaTypeEnum")
    private String mediaType;
    
    @ApiModelProperty("类型：0，普通，1：置顶")
    private Integer type;

    @ApiModelProperty("评论内容")
    private String content;
    
    @ApiModelProperty("是否已点赞")
    private Boolean hasSupport;

    @ApiModelProperty("点赞量")
    private Integer likedCount;

    private String userNickname;

    private String userAvatar;
    
    @ApiModelProperty("发表时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime createTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private LocalDateTime updateTime;
    
    @ApiModelProperty("该评论下的回复")
    private Page<ReplyVO> replyVoPage;
    
}
